//
//  TabBarViewController.m
//  HomeDelivery
//
//  Created by apple on 16/7/25.
//  Copyright © 2016年 apple. All rights reserved.
//

#import "TabBarViewController.h"
#import "PersonalCenterViewController.h"
#import "ManagerViewController.h"
@interface TabBarViewController ()

@end

@implementation TabBarViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    [self setUpViewControllers];
    self.view.backgroundColor=[UIColor whiteColor];
    [[UITabBarItem appearance]setTitleTextAttributes:@{NSForegroundColorAttributeName:[UIColor lightGrayColor]} forState:UIControlStateNormal];
    [[UITabBarItem appearance]setTitleTextAttributes:@{NSForegroundColorAttributeName:ORANGE} forState:UIControlStateSelected];
}
-(void)setUpViewControllers
{
    ManagerViewController *manager=[[ManagerViewController alloc]init];
    manager.tabBarItem.title=@"订单中心";
    manager.tabBarItem.image=[[UIImage imageNamed:@"steward_up"]imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
    manager.tabBarItem.selectedImage=[[UIImage imageNamed:@"steward_down"]imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
    UINavigationController *mangerNav=[[UINavigationController alloc]initWithRootViewController:manager];
    
    
    
    PersonalCenterViewController *personalCenter=[[PersonalCenterViewController alloc]init];
    personalCenter.tabBarItem.title=@"个人中心";
    personalCenter.tabBarItem.image=[[UIImage imageNamed:@"mine_up"]imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
    personalCenter.tabBarItem.selectedImage=[[UIImage imageNamed:@"mine_down"]imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
    UINavigationController *personalNav=[[UINavigationController alloc]initWithRootViewController:personalCenter];
    self.viewControllers=@[mangerNav,personalNav];
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
}


@end
